import java.io.File;
import java.io.IOException;
// 文件练习
public class Demo4 {
    public static void main(String[] args) throws IOException {
        File file=new File("ccs1.txt");
       //file.createNewFile();
        System.out.println(file.getParent());
        System.out.println(file.getName());
        System.out.println(file.getPath());
        System.out.println(file.getAbsolutePath());
        System.out.println(file.exists());
        System.out.println(file.isDirectory());
        System.out.println(file.isFile());
        System.out.println(file.createNewFile());
    }  
}
